<!DOCTYPE html>
<html lang="en">
<head>
    <% var data = { name: 'archives' } %>
    <%- include('base/head', data) %>
</head>
<body>
<%- include('loading', data); %>
<div id="app">
    <!--<div class="wrapper">-->
    <%- include('base/nav', data); %>
    <div class="jumbotron"
         style="background-image:url('https://image.cdn.mbdoge.cn/17-1-12/40769947-file_1484187390610_17ae7.png?imageView2/2/w/1928/format/jpg');background-position: 0 -235px">
        <div class="container j-vertical-center">
            <h1>文章归档</h1>
            <p>观察下自己的写文水平的进阶线。这里只有原创，转载不会列出来哦~ 就看我能写几篇，写几天，或者....几年？</p>
        </div>
    </div>
    <div class="container j-archives-times">
        <%
        var list, item, category, dateTime, time, date, user, url
            for (var key in groupData) {
            list = groupData[key]
        %>
        <div class="j-archives-item">
            <div id="<%= moment(key, 'MMM YY').format('YYYYMM') %>" class="j-start-date"
                 title="<%= moment(key, 'MMM YY').format('YYYY年MM月') %>">
                <%= key %>
            </div>
            <%
            for (var i = 0, l = list.length; i < l; i++) {
                item = list[i]
                category = item.getCategoryOrTags().category
                dateTime = formatDate(item.post_date, 'YYYY/MM/DD HH:mm')
                time = formatDate(item.post_date, 'MMMM Do')
                date = formatDate(item.post_date, 'YYYY/MM/DD')
                user = item.user
                url = '/article/' + item.guid
            %>
            <div class="j-activity">
                <div class="j-timeline">
                    <time datetime="<%= dateTime %>"><%= time %></time>
                </div>
                <div class="j-content">
                    <a href="<%= url %>">
                        <h2 class="j-article-title am-text-lg">
                            <%= item.post_title %>
                        </h2>
                    </a>
                    <ul class="j-article-info list-inline">
                        <li class="j-article-author">
                            <img alt="<%= user.display_name %>"
                                 src="<%= user.user_avatar %>"
                                 class="article-avater" width="20" height="20">
                            <a><%= user.user_nickname %></a>
                        </li>
                        <li class="j-article-author">
                            <font-icon type="icon-color-ziyuan" size="14"></font-icon>
                            <span><%= category.name %></span>
                        </li>
                        <li class="j-time">
                            <font-icon type="icon-color-rili" size="14"></font-icon>
                            <span><%= date %></span>
                        </li>
                    </ul>
                </div>
            </div>
            <% } %>
        </div>
        <div class="j-divider">
            <span>divider</span>
        </div>
        <!--<Divider orientation="right">厉害的分割</Divider>-->
        <% } %>
    </div>
    <%- include('base/bottom', data); %>
</div>
<%- include('base/footer', data); %>
</body>
</html>
